package com.content.view.Component.Button
{
	import com.content.model.LoadedAssets.FontProxy;
	import com.library.core.IDisposable;
	import com.library.core.UIObject;
	import com.library.utils.TextFieldUtil;
	
	import flash.display.DisplayObject;
	import flash.events.MouseEvent;
	import flash.text.TextField;
	
	public class TextButtonICO extends UIObject implements IDisposable
	{
		public var id:String;
		
		private var _obj:DisplayObject;
		protected var _text:TextField;
		
		public function TextButtonICO(obj:DisplayObject, txt:String)
		{
			super();
			this.mouseChildren = false;
			this.buttonMode = true;
			
			_text = TextFieldUtil.Generate( txt, 14, 0xffffff, FontProxy.FONT_YAHEI); 
			addChild(_text);
			
			_obj = obj;	
			if(_obj != null){
				addChild(_obj);
				_text.x = _obj.x + _obj.width;
			}
			
		}
		
		public function Dispose():void
		{
		}
	}
}